# Contributor: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
# Maintainer: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
pkgname=py3-ast-monitor
pkgver=0.1.5
pkgrel=1
pkgdesc="A wearable Raspberry Pi computer for cyclists"
url="https://github.com/firefly-cpp/AST-Monitor"
arch="noarch !s390x !riscv64 !armhf !ppc64le" # py3-sport-activities-features # py3-pyqt-feedback-flow
license="MIT"
depends="
	python3
	py3-geopy
	py3-matplotlib
	py3-pyqt-feedback-flow
	py3-qt5
	py3-qtwebengine
	py3-sport-activities-features
	py3-tcxreader
	"
checkdepends="python3-dev py3-pytest"
makedepends="py3-build py3-poetry-core py3-wheel py3-installer"
subpackages="$pkgname-doc"
source="https://github.com/firefly-cpp/AST-Monitor/archive/$pkgver/ast_monitor-$pkgver.tar.gz"
builddir="$srcdir/AST-Monitor-$pkgver"

build() {
	GIT_DIR="$builddir" python3 -m build --no-isolation --wheel
}

check() {
	python3 -m pytest
}

package() {
	python3 -m installer -d "$pkgdir" \
		dist/ast_monitor-$pkgver-py3-none-any.whl

	install -Dm644 docs/preprints/2109-13334.pdf -t "$pkgdir"/usr/share/doc/$pkgname
}

sha512sums="
3f15e25ae1d4adfdcb6d5f78467a862a628256868defe76f2dc4ad7033214357ff84b0bdebcd377be53101f133491e3653ca3227622b8b5673520b440b520aae  ast_monitor-0.1.5.tar.gz
"
